using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;

namespace WorldEditor
{
    public class PanelWithEvents : System.Windows.Forms.Panel
    {
        public new event KeyEventHandler KeyDown;
        public new event KeyEventHandler KeyUp;

        public PanelWithEvents()
            : base()
        {
        }

        public new void OnKeyDown(System.Windows.Forms.KeyEventArgs e)
        {
            if (KeyDown.Method != null)
                KeyDown.Invoke(this, e);
        }

        public new void OnKeyUp(System.Windows.Forms.KeyEventArgs e)
        {
            if (KeyUp.Method != null)
                KeyUp.Invoke(this, e);
        }
    }
}
